Skip to content

Conversation

@harshil1712
Copy link
Contributor

Summary

Add notes to clarify overlapping event rules. Fixes #17949

@github-actions github-actions bot added the product:r2 R2 object storage: https://developers.cloudflare.com/r2 label Jan 10, 2025
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Jan 10, 2025

Deploying cloudflare-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: bfcff78
Status: ✅  Deploy successful!
Preview URL: https://d0cfb331.cloudflare-docs-7ou.pages.dev
Branch Preview URL: https://r2-event-notification-note.cloudflare-docs-7ou.pages.dev

View logs

@github-actions
Copy link
Contributor

@bthwaites
Copy link
Contributor

This isn't quite accurate. You would be allowed to configure one rule with PutObject, prefix a/, and another with CopyObject, prefix a/. The key point is that we will reject any rule that overlaps with another rule such that multiple rules may trigger from the same R2 request. I'd suggest something like this:

  • Rule prefixes and suffixes for the same R2 action may not overlap in such a way that could cause multiple rules to trigger at once. For example, a rule with PutObject and prefix * and a rule with PutObject and prefix a/ would both match an object named a/b, and therefore may not be configured at the same time.

What do you think @jonesphillip ?

@harshil1712
Copy link
Contributor Author

Thank you @bthwaites. I checked with @jonesphillip and have made the changes.

@harshil1712 harshil1712 merged commit 2700dce into production Jan 23, 2025
12 checks passed
@harshil1712 harshil1712 deleted the r2-event-notification-note branch January 23, 2025 15:31
deadlypants1973 pushed a commit that referenced this pull request Jan 29, 2025
* add note for overlapping event rules

* clarify confliciting rules
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

product:r2 R2 object storage: https://developers.cloudflare.com/r2 size/xs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add documentation regarding conflicting event notification rules

5 participants